package com.aiyige.base;

public class JSNativeResponse {
    public static final String RESULT_SUCCESS = "success";
    public static final String RESULT_FAILED = "failed";
    String result;
    String data;

    public JSNativeResponse() {
    }

    private JSNativeResponse(Builder builder) {
        setResult(builder.result);
        setData(builder.data);
    }

    public static Builder newBuilder() {
        return new Builder();
    }

    public String getResult() {
        return result;
    }

    public void setResult(String result) {
        this.result = result;
    }

    public String getData() {
        return data;
    }

    public void setData(String data) {
        this.data = data;
    }

    public static final class Builder {
        private String result;
        private String data;

        private Builder() {
            result = "";
            data = "";
        }

        public Builder result(String val) {
            result = val;
            return this;
        }

        public Builder data(String val) {
            data = val;
            return this;
        }

        public JSNativeResponse build() {
            return new JSNativeResponse(this);
        }
    }
}
